package com.libui.thirdpartsdk.share.models

interface ShareObjectInterface {
    val type: ShareObjectType

    /*
    * 分享标题
    * */
    val title: String?

    /*
    * 分享描述
    * */
    val description: String?

    /*
    * 分享缩略图
    * */
    val thumbImage: ByteArray?

    fun toJson(): Map<String, Any> {
        val json = mutableMapOf(
            "type" to type.title,
        )

        title?.let {
            json["title"] = it
        }

        description?.let {
            json["description"] = it
        }

        return  json
    }
}